<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Title</title>

</head>
<body>
<!--需求：点击列表中的哪一项，那么该项的颜色更改为红色-->
<div id="app">
    <ul>
<!--      <li v-for="变量 in movies">-->
      <li v-for="(item,index) in movies" v-bind:class="">
        {{index}}-{{item}}
      </li>
    </ul>
</div>

<script src="../js/vue.js"></script>
<script>
    const vue = new Vue({
        el:'#app',
        data:{
            movies:['海王','海尔兄弟','火影忍者','进击的巨人']
        },

    })
</script>
</body>
</html>